#!/usr/bin/env bash

set -e

SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)

rm -rf "$SCRIPT_DIR/Generator/bin/cuckoonator"
env -i PATH="$PATH" HOME="$HOME" xcodebuild build \
    -project "$SCRIPT_DIR/Generator/Generator.xcodeproj" \
    -scheme Generator \
    -configuration Release
